package com.atguigu.admin.service;

import com.atguigu.admin.bean.City;
import com.atguigu.admin.mapper.CityMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author anan
 * @create 2021-09-02 18:49
 */
@Service
public class CityService {
    @Autowired
    CityMapper cityMapper;

    public City getById(Long id){
       return cityMapper.getById(id);
    }

    public void saveCity(City city) {
        cityMapper.insertCity(city);
    }
}
